<template>
    <v-details :detailData="data.detailData" :inputConfig="inputConfig" :rules="rules" ref="input"></v-details>
</template>

<script>

    import details from 'commons/Detail'
    import baseMixin from "@/mixins/BaseMixin";

    export default {
        name: "",
        mixins: [baseMixin],
        props: {
            data: {
                type: Object
            }
        },
        data() {
            return {
                rules: {
                    userlinenumber: [
                        {required: true, trigger: 'blur'},
                    ],
                    areakey: [
                        {required: true, trigger: 'blur'},
                    ],
                     permissiontype: [
                        {required: true, trigger: 'blur'},
                    ],
                },
            }
        },
        computed: {
            inputConfig() {
                return [
                    [
                        {
                            type: "input",
                            label: this.$t('outbound.userlinenumber'),
                            props: "userlinenumber",
                            disabled: true
                        },
                        {
                            type: "select",
                            label: this.$t('outbound.permissiontype'),
                            props: "permissiontype",
                            options: this.getOptions("codelkup/ACTIVTYPE")
                        }
                    ],
                    [
                        {
                            type: "select",
                            label: this.$t('config.area'),
                            props: "areakey",
                            options: this.getOptions("queryareaDetail1")
                        },
                        {
                            type: "checkbox",
                            label: this.$t('outbound.permission'),
                            props: "permission",
                        }
                    ],
                ]

            }
        },
        methods: {},
        mounted() {
        },
        watch: {},
        components: {
            'v-details': details
        }
    }
</script>

<style scoped>

</style>
